import {Editor, Element as SlateElement, Point, Range, Transforms} from "slate";
import {onKeyDown} from '../elements/Table/TableEvent';

const ON_KEY_DOWN = [];
export const editorEventHandler = (type, e, editor) => {

    if ('onKeyDown' === type ) {
        const [match] = Editor.nodes(editor, {
            match: n => n.type === 'table'
          });
        if (!!match) {
            onKeyDown(e, editor);
        }
    }

    return editor;
}